-
Notifications
You must be signed in to change notification settings - Fork 31
Draft of generic fractional ownership DAO #57
Conversation
```ocaml | ||
%vote { | ||
lambda: unit -> operation; | ||
nonce: nat; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what is the purpose of the nonce
here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To prevent a replay attack. See how vote_nonce
is used in existing fractional DAO
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it strictly increasing? In that case, maybe counter
would be clearer? Otherwise, why isn't it strictly increasing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it is strictly increasing
please also make the relevant PR to the minter-sdk repo: tqtezos/minter-sdk#11 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
: dao_lambda * permit * nat) : address = | ||
let signed_data = Bytes.pack ( | ||
(Tezos.chain_id, Tezos.self_address), | ||
(vote_count, lambda) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn't follow exactly the signing procedure in Tzip-17(https://gitlab.com/tzip/tzip/-/blob/master/proposals/tzip-17/tzip-17.md#submission) where the parameter is packed and then hashed with BLAKE2B
but I suppose that is unnecessary in this context since the un-obfuscated parameter is passed to the entrypoint at the same time anyway
No description provided.